package task;

import java.util.Scanner;

public class Task4_1 {
    public static void main(String[] args) {
        Scanner input = new Scanner(System.in);
        int a = input.nextInt();
        swap(a);
        
    }
    public static void swap(int n){
        System.out.print("偶数位：");
        for (int i = 30; i >= 0; i-= 2) {
            System.out.print(((n >> i) & 1));
        }
        System.out.println();
        System.out.print("奇数位：");
        for (int i = 31; i >= 1; i-= 2) {
            System.out.print(((n >> i) & 1));
        }
        /*int[]  a = new int[32];
            for (int i = 0; i < a.length; i++) {
                a[i] = n % 2;
                n = n / 2;
            }
        System.out.println("偶数位：");
        for (int i = a.length - 1; i >= 0; i -= 2) {
            System.out.print(a[i]);
        }
        System.out.println("\n");
        System.out.println("奇数位：");
        for (int i = a.length - 2; i >= 0 ; i -= 2) {
            System.out.print(a[i]);
        }*/
        }
        
    }

